import http from "@/api";

import { ResPage } from "@/api/interface";

 
import { ModuleCommonUrl } from "..";
import { CommonUseEntity, CommonUseVo } from "@/biz/interface/CommonUse";

const moduleUrl = ModuleCommonUrl;

// * 获取列表
export const getCommonUseVoListApi = (params: {}) => {
  return http.post<ResPage<CommonUseVo>>(moduleUrl + `/comhximapi/cmusebyuservolist`, params);
};

// * 新增接口
export const saveCommonUseApi = (company: CommonUseEntity) => {
  return http.post(moduleUrl + `/comhximapi/cmusesave`, company);
};

// * 详情接口
export const getCommonUseInfoApi = (params: { id: string }) => {
  return http.post<CommonUseEntity>(moduleUrl + `/comhximapi/cmuseinfo`, params);
};

// * 删除接口
export const deleteCommonUseApi = (params: { id: string }) => {
  return http.post(moduleUrl + `/comhximapi/cmusedelete`, params);
};
